How to refactor an async function with Promise inside of it

welcome to shbcf.ru